package com.chancingpack.dal.dao.mybatis;

import com.chancingpack.dal.dao.WxSendMessageDao;
import com.chancingpack.dal.model.WxSendMessage;
import com.chancingpack.dal.service.WxSendMessageMapper;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Repository;

import java.util.List;
import java.util.Map;

/**
 * Created by lenovo on 2017/7/14.
 */
@Repository
public class WxSendMessageDaoImpl implements WxSendMessageDao {

    /**
     * 自动注解，实例化
     */
    @Autowired
    private WxSendMessageMapper wxSendMessageMapper;

    /**
     * 录入发货信息数据
     * @param wxSendMessage
     * @return
     */
    public boolean insertSendMessage(WxSendMessage wxSendMessage) {
        return wxSendMessageMapper.insertSelective(wxSendMessage) > 0;
    }

    public List<Map<String, Object>> selectcustName() {

        return wxSendMessageMapper.selectcustName();
    }

    public List<Map<String, Object>> selectSendpage(Map<String,Object> map) {
        return wxSendMessageMapper.selectSendpage(map);
    }

    public List<Map<String, Object>> selectBydetailId(Map<String, Object> map) {
        return wxSendMessageMapper.selectBydetailId(map);
    }

    public List<Map<String, Object>> selectByReceive(Map<String, Object> map) {
        return wxSendMessageMapper.selectByReceive(map);
    }

    public boolean insertsend(WxSendMessage record) {
        return wxSendMessageMapper.insertsend(record)>0;
    }

    public List<Map<String, Object>> selectSendBydetailId(Map<String, Object> map) {
        return wxSendMessageMapper.selectSendBydetailId(map);
    }

    public int selectCount(Map<String, Object> map) {
        return wxSendMessageMapper.selectCount(map);
    }

    public List<Map<String, Object>> selectSend(Map<String, Object> map) {
        return wxSendMessageMapper.selectSend(map);
    }
}
